import request from '@/utils/request'

// 查询监测指标列表
export function listVariable(query) {
  return request({
    url: '/oil/variable/list',
    method: 'get',
    params: query
  })
}

// 查询监测指标详细
export function getVariable(id) {
  return request({
    url: '/oil/variable/' + id,
    method: 'get'
  })
}

// 新增监测指标
export function addVariable(data) {
  return request({
    url: '/oil/variable',
    method: 'post',
    data: data
  })
}

// 修改监测指标
export function updateVariable(data) {
  return request({
    url: '/oil/variable',
    method: 'put',
    data: data
  })
}

// 删除监测指标
export function delVariable(id) {
  return request({
    url: '/oil/variable/' + id,
    method: 'delete'
  })
}
